package com.thghh.gkrpc.codec;

import com.alibaba.fastjson.JSON;

/**
 * @author Zhikang.Peng
 * @version 1.0
 * @email thghh@qq.com
 * @date 2020/4/11 10:23
 */
public class JSONEncoder implements Encoder {

    @Override
    public byte[] encode(Object obj) {
        return JSON.toJSONString(obj).getBytes();
    }
}
